package scottb.flex.navigate;

import scottb.flex.FlexPanel;

import java.awt.*;

public class NavItem implements INavItem {

    private String id;
    private Component view;
    private EnterHandler enterHandler;
    private ExitHandler exitHandler;

    public NavItem(String id, Component view) {
        this(id, view, null, null);
    }

    public NavItem(String id, Component view, EnterHandler enterHandler) {
        this(id, view, enterHandler, null);
    }

    public NavItem(String id, Component view, ExitHandler exitHandler) {
        this(id, view, null, exitHandler);
    }

    public NavItem(String id, Component view, EnterHandler enterHandler, ExitHandler exitHandler) {

        this.id = id;
        this.view = view;
        this.enterHandler = enterHandler;
        this.exitHandler = exitHandler;
    }

    public String getId() {
        return id;
    }

    public Component getView() {
        return view;
    }

    public EnterHandler getEnterHandler() {
        return enterHandler;
    }

    public ExitHandler getExitHandler() {
        return exitHandler;
    }
}
